#{extends 'main.html' /}
#{if candidates==null}
<h1>You have already voted for this election.</h1>
#{/if}
#{else}
<h1>${election.Title}</h1>
<h2>${election.QuestionBody}</h2>
#{if candidates.size()==0}
No candidates for this election yet.
#{/if}
#{list items:candidates, as:'candidate'}
<b><a href="/Answers/ChooseAnswer?id=${candidate.id}">${candidate.CandidateName}</a></b></b><br>
#{/list}
#{/else}
<br><br><br><br>
#{if user.isAdmin}

<a href="/Questions/end?id=${election.id}">End this vote</a>
#{/if}